<{css src="ecmall.css" app="business"}>
<div class="content">
<div class="reg new_reg dis_bl">
        <div class="title">
            <div class="title_img">
                <img src="<{$env.base_url}>/app/business/statics/images/reg_stpe.jpg" alt="" />
            </div>
        </div>
        <div class="reg_step_2">
            <div class="reg_shop">
                   <{foreach from=$sgrades item=sgrade}>
                        <{switch  from=$sgrade.issue_type}>
                         <{case value=0}>
                           <{assign var="issuename" value='卖场型旗舰店'}>
                           <{assign var="issuepic" value="step_2_02.png"}>
                         <{case value=1}>
                           <{assign var="issuename" value='专卖店'}>
                           <{assign var="issuepic" value="step_2_03.png"}>
                         <{case value=2}>
                           <{assign var="issuename" value='专营店'}>
                           <{assign var="issuepic" value="step_2_04.png"}>
                         <{case value=3}>
                           <{assign var="issuename" value='品牌旗舰店'}>
                           <{assign var="issuepic" value="step_2_01.png"}>
                         <{/switch}>
                   <div class="fl" id="<{$sgrade.grade_id}>" >
                        <h3><{$issuename}></h3>
                        <p class="reg_shop_info">
                           <{$sgrade.remark}>
                        </p>
                   </div>
                   <{if $issuename=='专营店'}>
                     <div class="fl" id="<{$sgrade.grade_id}>wm" >
                        <h3>热品店</h3>
                        <p class="reg_shop_info">
                           <{$sgrade.remark}>或没有没有品牌的店铺。
                        </p>
                   </div>
                   <{/if}>
                   <{/foreach}>
                <div class="crl"></div>
                <div class="t_c">
                <a  id='nextstep'  href="<{link app='business' ctl='site_store' act='storeapplystep2' arg0='gradeid' }>" class="reg_step_2_button">下一步 &gt;</a><div class="crl"></div></div>
            </div>
        </div>
    </div>
</div>
<script>
 window.addEvent('domready',function(){

        $$('.fl').addEvents({
        click:function(){
            $$('.fl').removeClass('active');
           this.addClass('active');
           var str="<{link app='business' ctl='site_store' act='storeapplystep2' arg0='gradeid'}>";
            str=str.replace('gradeid',this.id.toInt())
           $('nextstep').href= str;

        }
        });

         if($$('.reg_shop .fl').length>0){
            $$('.reg_shop .fl')[0].addClass('active');
            var str="<{link app='business' ctl='site_store' act='storeapplystep2' arg0='gradeid'}>";
        
            str=str.replace('gradeid', $$('.reg_shop .fl')[0].id.toInt())
           $('nextstep').href= str;
        }



   });


</script>

